<?php
/* @var $this BackendController */
/* @var $model Category */
Yii::app()->clientScript->registerScript('dropdown',"$(function(){ $('.dropdown-toggle').dropdown();});");
$this->breadcrumbs=array(
    Yii::t('CategoryModule.base','Categories')=>array('index'),
    Yii::t('CategoryModule.base',$model->name),
);

$this->menu=array(
    array('label'=>'<span class="glyphicon glyphicon-list-alt"></span>&nbsp'.Yii::t('CategoryModule.base','List Category'), 'url'=>array('index')),
	array('label'=>'<span class="glyphicon glyphicon-plus-sign"></span>&nbsp'.Yii::t('CategoryModule.base','Create Category'), 'url'=>array('create')),
	array('label'=>'<span class="glyphicon glyphicon-cog"></span>&nbsp'.Yii::t('CategoryModule.base','Manage Category'), 'url'=>array('admin')),

    array('label'=>'<span class="glyphicon glyphicon-wrench "></span>&nbsp'.Yii::t('CategoryModule.base','Operations').'&nbsp<span class=caret></span>','url'=>array('#'),'itemOptions'=>array('class'=>'dropdown','aria-labelledby'=>'dLabel'),'items'=>array(
        array('label'=>'<span class="glyphicon glyphicon-refresh"></span>&nbsp'.Yii::t('CategoryModule.base','Update Category'), 'url'=>array('update', 'id'=>$model->id),'linkOptions'=>array('role'=>'menuitem','tabindex'=>-1),'itemOptions'=>array('class'=>'dropdown','role'=>'presentation')),
        array('label'=>'<span class="glyphicon glyphicon-trash"></span>&nbsp'.Yii::t('CategoryModule.base','Delete Category'), 'url'=>'#', 'linkOptions'=>array('submit'=>array('delete','id'=>$model->id),'confirm'=>Yii::t('CategoryModule.base','Are you sure you want to delete this item?'))),
    ),
        'submenuOptions'=>array('class'=>'dropdown-menu', 'role'=>"menu",'aria-labelledby'=>"drop1"),
        'linkOptions'=>array('class'=>'dropdown-toggle','id'=>'dLabel','data-toggle'=>'dropdown')
    ),
);
?>
<?php if(Yii::app()->user->hasFlash('success')):?>
    <div class="alert alert-success">
        <?php echo Yii::app()->user->getFlash('success');?>
    </div>
<?php endif;?>
<h3><?php echo Yii::t('CategoryModule.base','View Category') ?></h3>

<?php $this->widget('zii.widgets.CDetailView', array(
	'data'=>$model,
	'attributes'=>array(
		'id',
		'name',
        array(
            'label'=>Yii::t('CategoryModule.base','Create Time'),
            'type'=>'raw',
            'value'=>$model->getCreateDateTimeFormat()
        ),
        array(
            'label'=>Yii::t('CategoryModule.base','Update Time'),
            'type'=>'raw',
            'value'=>$model->getUpdateDateTimeFormat()
        ),
		'tags',
		array(
            'label'=>Yii::t('CategoryModule.base','create_user_id'),
            'type'=>'raw',
            'value'=>$model->getCreateUserData()
        ),
        array(
            'label'=>Yii::t('CategoryModule.base','update_user_id'),
            'type'=>'raw',
            'value'=>$model->getUpdateUserData()
            // 'template'=>"<tr class=\"{class}\"><th>{label}</th><td><span itemprop=\"name\">{value}</span></td></tr>\n",
        ),
	),
)); ?>
